#ifndef _webcam_h
#define  _webcam_h
#include "headfile.h"
#include "common.h"


#define CROSSROAD  0
#define ROUNDISLAND  1
#define GARAGE 2
extern int  huandao_memory ,right_turn_down[2],right_turn_middle[2],right_turn_up[2],left_turn_out[2],flag_find_huan_rightdown_point,flag_find_huan_rightmiddle_point,flag_find_huan_rightup_point;
void search_line();
void garage_judge();
void garage_start();
extern int LeftEdge[],RightEdge[], MiddleLine[],left_find,right_find;
extern int Right_bihe;
void geterror(void);
float leastSquares(void);
void turnDeal(void);
void imageDeal(void);
extern float DireControlOut;
void 	direction(void);
extern float Error,cha;
extern float cameraError;
extern uint8 width[];
void twovaluse_format(void);
int getThreshold(void);
void Huandao_judge(void);
void Huandao_buxian(void);
extern uint8  dis_image[MT9V03X_H][MT9V03X_W];
extern uint8 image_threshold; 	
#endif
